package utildb;

import java.sql.Date;
import java.util.Calendar;

public class Fecha {
	
   public static Date getFechaActual(){  	
   	Calendar calendar = Calendar.getInstance();		
   	java.util.Date temp = calendar.getTime();
   	Date hoy = new Date(temp.getTime());
	return hoy;	
   }
   
   public static Date getFecha(Date f1, int totalDias){
	Calendar calendar = Calendar.getInstance();
	calendar.setTime(f1);
	calendar.add(Calendar.DAY_OF_MONTH,totalDias);
	Date f2 = new Date(calendar.getTime().getTime());
	return f2;
   }
}
